Tally instruction apparatus for automatic digital computers



Feb. 24 1959 G HOLMES 2,874,901

1115.1 DISTRUCTION APPARATUS FOR AUTOMATIC DIGITAL COMPUTERS Filed De:` S. 1954 3 Sheets-Sheet 1 I I I I ll'lll 1li... lllllllll ||II III III IIJ n Sv E @Mmmm 5w..

I @N .m6 Q mw Illu-LII IIIJ `N n x u Feb. 24, 1959 T. G. HOLMES 5 Sheets-Sheet 2 KRO Rum (u huhu@ wu Feb. 24, 1959 T. G. HoLMEs TALLY INSTRUCTION APPARATUS FOR AUTOMATIC DIGITAL COMPUTERS Filed Dec. 8, 1954 3 Sheets-Sheet 3 ...ww SNI United States Patent O TALLY INSTRUCTION APPARATUS FOR AUTO- MATIC DIGITAL COMPUTERS Thomas G. Holmes, Melbourne, Fla. Application December 8, 1954, Serial No. 474,044

Claims. (Cl. 23S-157) (Granted under Title 35, U. S. Code (1952), sec. 266) 'I'he invention describedherein may be manufactured and used by or for the Government of the United States for governmental purposes without payment to me of any royalty thereon.

Automatic digital computers have four basic components: the memory or storage component, the arithmetic component, the terminal component and the control component.

The memory or storage component consists of a number of storage locations or cells into which information can be inserted for storage and from which information can be extracted when needed by the computer. Numbers on which operations are to be performed, the results of such operations and instructions governing the operation of the computer are stored in the various memory cells. Each cell is identified by an address number.

The arithmetic component of the computer comprises all of the apparatus necessary to perform the arithmetic operations of addition, subtraction, multiplication and division.

The terminal component comprises all of the apparatus required to transfer information into and out of the computer.

Finally, the control component, with which this invention is concerned, comprises all of the apparatus required to take instructions from the memory, to analyze these instructions and to issue appropriate commands causing the computer to execute the instructions.

It is the object of this invention to simplify the instruction programing of iterative operations. Briefly, this is accomplished by providing, as part of the control component, apparatus operative in response to a special instruction, termed a tally instruction, to cause the computer to repeatedly refer to and carry out a single instruction stored in one of the cells of the memory. Both the address of the instruction to be repeated and the number of repetitions desired are designated in the tally instruction. The apparatus makes use of a special counter, referred to as the base counter, for keeping a tally of the number of times the designated instruction has been performed during execution of the tally instruction. Also, as will be explained in more detail later, one or more of the addresses in the repeated instruction are made relative to the base counter, which is reset at each execution by the tally instruction, so that the tally instruction is able to effectively modify these addresses without altering the repeated instruction itself. When the tally equals the number of repetitions specified in the tally instruction the computer automatically refers to the next instruction in the sequence of instructions stored in the memory.

A more detailed description of the invention will be given in connection with the speciiic embodiment thereof shown in the accompanying drawings in which Fig. 1 illustrates the composition of an instruction word in the specific embodiment described, and

Fig. 2 is a logical diagram of that part of the computer control component involved in execution of the tally in struction, and

"2,874,901` Patented Feb. 24, 1959 Figs. 3 and 4 show timing diagrams for the execution of a tally instruction and an arithmetic instruction, respectively.

In the specific embodiment of the invention described herein a computer word, i. e. the group of digits representing a number or an instruction, consists of 48 binary digits in the form of a serial electrical pulse code having a pulse frequency of one megacycle per second. The component parts of both number and instruction words are shown in Fig. l. Electrical pulses are present or absent at the time positions of digits P1P48 depending upon whether the particular digit is a 1 or a 0. The length of a word is 48 microseconds, this period being designated a minor cycle. Digits Pw-P are not normally used and may be regarded as zeros.

In the case of a number word, digit P1 represents the sign or of the number and digits PTP its absolute value, P2 being the least significant digit. In the case of an instruction word, digit P1 has no signiicance as a sign but may be utilized for some special function such as halting the computer; digits P2-P5 constitute a 4-digit code designating the operation to be performed; digits Pe-Pg constitute a 4-digit relative address control group; and remaining digits P10-P45 are divided into three 12` digit groups designated a, and v. Such an instruction is of the three-address type, 1, and y being the three addresses, and normally contains no information as to the location of the next instruction. Therefore the instructions must be arranged in sequence in the memory and a control counter that is increased by one each time an instruction is performed is required to designate the memory cell containing the next instruction. The control counter may be reset by certain logical operations including the tally instruction as will be seen later.

In conventional instructions the numbers n, and 'y may be absolute or they may be relative to a control counter Cc or a base counter Cb as determined by the digits a, b, c, d of the relative address control group. Accordingly, the etfective values ne, e and ye of these where a, b and c are either l or O and (0.,) and (Cb) represent the contents of the control and base counters respectively. As summarized in the above equations, the effective value of an address is its absolute value modified by the contents of either the control counter or the base counter, If the address is absolute, its effective value equals its absolute value. If relative, the effective value equals its absolute value plus the contents of one of the counters. The digits a, b and c indicate Whether the associated addresses alpha, beta and gamma are absolute (digit=0) or relative (digit=l). The digit d indicates the counter to which the address is relative (d=0 indicates control counter and d=1 indicates base counter). For example, in the case oi the alpha address the effective value equals alpha when the address is absolute (a=0). When relative (11:1), the elfective value equals alpha plus the contents ofthe control counter (d=0) or alpha plus the contents of the base counter (d=1). The function of the control counter has already been described. The base counter is an additional counter used as an adjustable reference point for relative addresses and as a. tally keeping device in the performance of the tally instruction. The base counter may be changed or reset by a tally instruction only, as will be seen later in the description of Fig. 2. The term base" is used simply to distinguish this counter from the control counter. Other than use, there is no essential dilerence m the two counters as will be apparent from the subsequent description of Fig. 2.

If the instruction calls for an arithmetic operation, a, and pe are the addresses in the memory of the two operands and 'ya designates the memory cell in which the result is to be stored. In instructions calling for nonarithmetic operations these numbers may or may not represent memory addresses depending upon the operation to be performed. For example, in an instruction to read a specified number of words from a specified input device into the memory beginning with a specified memory cell, e may represent the number of words, may designate the input device, and 'ya may be the address of the memory cell receiving the first word.

The tally instruction differs from conventional instructions of the above type in that the relative address feature is more restricted, In the tally instruction a and if relative, are always relative to the base counter and v, if relative, is always relative to the control counter. Thus, in the tally instruction,

These equations characterize the tally instruction in the same manner that the preceding equations characterize conventional instructions. The digits a, b and c, which appear in the control group (CG) of the instruction (Fig. 1), determine Whether the corresponding address is absolute or relative as explained for the preceding equations. The control digit d in this case does not designate the reference counter but serves a special purpose which will be explained later.

In the tally instruction, u designates the amount by which the base counter is increased each time the tally instruction is executed. Its value is usually one but may be greater than one in certain cases as will be shown later. The number is indicative of the number of times the designated instruction is to be repeated. The 'y number is the memory address, absolute or relative depending upon the value of c, of the instruction to be repeated.

In executing the tally instruction the control component of the computer determines ce, e and ye, and compares the binary number a., with the binary number se. Depending upon this comparison one of the following two courses of action takes place:`

(l) us ez The base counter Cb is reset to e and the control counter C is reset to we. The computer therefore looks for its next instruction in the memory cell Whose address is 7,.

(2) natre: Cb is reset to ae if d=0 and to 0 if d=1. One is added to the contents of the control counter so that the computer is referred to the next instruction in the sequence of instructions.

As already mentioned a, and 'y are each 12dgit binary numbers. In order to abbreviate the writing of instructions as much as possible the hexadecimal system of binary notation is used. In this system each of the sixteen possible combinations of tour binary digits are designated by hexadecimal digits as follows:

Binary Binary Thus the binary number 100011010110 becomes the hexadecimal number 8D6. In an instruction written in hexadecimal form u, and 'y are each represented by be of the form OG OPN As is apparent from the preceding table, the alpha address 61B is the binary number similarly the beta address 032 is the binary number 000000110010 and the gamma address 00D is the binary number 000000001101. sented by hexadecimal B is the the operation code OPN represen the binary number 0011.

The following example uses of the tally instruction. These examples The control group CG reprebinary number 1011 and ted by hexadecimal 3 is s will serve to illustrate specific involve the use of various instructions which are defined below:

Code Operation Description 0 Input Insert a. number oi words from input urt into memory starting with y. memory ce Number Con- (a) B even: Convert decimal number in a.

version. to binary and insert in y..

(b) B odd: Convert binary number in a. to

decimal and insert in y.. 4 Subtraction..--. Subtract contents of B. from contents of ne.

and place the difference in y.. 5 Addition Add the contents of a. to the contents of B.

and place the sum in 1.. 9 Multiplication Multiply contents of a. by contents ot (rounded). and place product, rounded to 44 binary digits. in y.. A. Tally Compares a. with..

If a Resets Cs to a. and C., to 1.. I t m.: Resots Ob to 0(b=1) or l(b=0) Adds ons to C...

(l) It is desired to add individually the 5 numbers in memory cells 012-016 to the 5 numbers in memory cells the sums in the 5 memory cells OOD-011 and place OOD-011.

tally instruction woul structions being place count in Cb being initially 000:

The coding for d be as fol this problem utilizing the lows, the necessary ind in cells 07A and 07B and the When the control counter reaches 07 instruction in operates in response to the the contents of cell 012 to place the sum in cell 00D, the sum rep this cell. The control counter then advances is the address of the cell containing the With Cb=000, ae=001 and =005.

Py=07A. Therefore in perform- G9 originally in to 07B which tally instruction.

Further, since c=0, we:

ing the tally instruction Ch tion in 07A.

this cell A the computer to add the contents of cell 00D and lacing the operand is reset to 001 and Cc is reset to 07A. The computer as a result returns to ero, 1

the instrucddress control group of the ddresses are relative (a, b,

e base counter (d=l).

the number n the lrst execution of ==00D and 'y='y=0D. instruction is referred to 6:013, 18e-00E and y=00E.

sum placed in E. .The computer is then advanced by the control counter to the tally instruction in 07B for the second time.

In the second execution of the tally instruction the contents of Cb is 001 instead of 000 and therefore ab, the number to which Cb is reset, becomes 002. Since this number is still less than 005, Cc is again reset to 07A and the computer refers to the instruction in this cell for the third time. In the third execution of this instruction, with Cb=002, ob=014, =0OF and 'ye=00F.

The above process continues until at the fourth reference to the tally instruction following the fourth execution of the instruction in 07A, Cb=004 and ae=005. Since ae now equals Se the fourth execution of the tally instruc tion causes Cb to be reset to 0 (d=1) and adds one to the contents of Cc (07B) thereby causing the computer to seek its next instruction in memory cell 07C.

(2) As a second example assume that it is desired to read ten data words from a specified input device into consecutive memory cells beginning with the cell whose address is OAO. Since input devices usually supply number words in binary coded decimal form it is necessary that these words be converted to true binary numbers. Utilizing the tally instruction and assuming the initial setting of the base counter Cb to `be 000, the coding may be as follows:

cui# a s y combed) OPN 0(0000). o B(1o11) a B(1o11) The instruction in cell 001 calls for reading ten (00A) words from input device 001 into consecutive memory cells starting with the memory cell whose address is 0A0. When this operation has been performed the control counter advances the computer to memory cell 002. The instruction in this cell calls for converting the number in cell 0A0 to binary form and storing the converted number in cell 0A0. The rz and y addresses in this instruction are relative to the base counter (a, c and d=l) but, since the initial setting of Cb is zero, acl-a and 78:7 in the initial execution of the instruction.

The conversion of the remaining nine numbers is accomplished through the tally instruction in cell 003. When this instruction is reached for the rst time Cb=000, ab=001 and {3er-00A. Since a= ;fe Cc is reset to 'ye and as a result the computer looks for its next instruction in 'ye which, being relative to the control counter (c=l), is 002 (FFF+003=002). Since Cb was reset to O01 by the tally instruction and since the a and y addresses of the instruction in 002 are relative to Cb, the second execution of this instruction causes the number in 0A1 to be convertcd to binary form and inserted in OAI.

The tally instruction is now reached for the second time. This time ae=002 which is still less than e and, by the above described process, results in Cc again being reset to ye or 002. The instruction in this cell is therefore executed a third time. Since now Cb=002, the third execution results in the number in 0A2 being converted and stored in OAZ.

After the tenth execution of the instruction in 002 the count in the base counter Cb stands at 009. Therefore, in the ensuing execution of the tally instruction ae=0A0=e. Consequently Cb is reset to 0 (d=1) and the control counter Cc is advanced by one to 004.

(3) Computing the algebraic sum of a plurality of numbers is another situation in which the tally instruction may be utilized to advantage. Assume it is desired to compute the algebraic sum of 15 numbers located in consecutive memory cells beginning with 07F. The sum will be accumulated in cell 00D. In contrast with the preceding problems it is assumed that the initial setting of the ibase counter Cb is 00A. The necessary instructions, located in memory cells 005, 006 and 007, are as follows:

The instruction in 005 clears 00D by subtracting the number in FFF from itself and placing the difference which is zero in 00D. Since the address in the instruction in 006 is relative to Cb( b, d=l), =075+00A=07F1 This instruction therefore specifies that the number in 00D be added to the number in 07F and the result placed in 00D. Since the number initially in 00D is 000 the first execution ofthe instruction eiectivcly places the number in 07F in 00D.

The control counter now advances the computer to the tally instruction in 007. Since the initial count in Cb is 00A, ze=001+00A=00B which is less than 023 (13e). Therefore the control counter Cc is reset to yb=Flr`Fl007=006 and the computer returns to the instruction in 006. In the second execution of this instruction the number in 00D is added to the number in 080 (075-t-OOB) and the sum placed in 00D.

The above process continues until after the 15th execution of the instruction in 006 the nal sum is in 00D and the count in Cb is 018. Consequently, in the next execution of the tally instruction a,=00lf018=019=e and the computer takes its next instruction from 008 (Cc-l-l), Cb being reset to 0 (d=1).

(4) In the preceding examples a in the tally instruction was always 001. In certain situations a may be an integer larger than one. For example, assume that it is desired to clear every other memory cell starting with cell 021 and ending with cell 03F. If the count in Cb is initially zero the necessary instructions, stored in memory cells 1F0 and IFI, are:

FFF

1F0 FFF DIF In the instruction in lFO fy is relative to Cb(c, d=l). Since initially Cb=000 the first execution of the instruction clears cell 021. In the second execution Cb=002 and cell 023 is cleared. After the last cell 03F has been cleared the count in Cb stands at 01E. Therefore in the following execution of the tally instruction ab=020 which is greater than OIF and results in Cb being reset to 0 (d=1) and one being added to Ce so that the computer looks for its next instruction in 1PZ.

(5) As a final example assume that it is desired to compute the value of the integral by Smpsons rule. If the interval of integration is divided into 20 subintervals of .05 radians each the value of this integral is given by the expression This expression may be rewritten as Assume further that the required 20 values of y=sin x are stored in consecutive memory cells starting with that the fractions and Cb is nero. The necessary instructions, stored in conseeuive memory eels 920-028, are as follows:

Cell# a 'y CG (abcd) OPN Remarks ozu K1 10o ooo oroooo) 9 uo 1n loo 1m x, 114 FFF oroooo) s p11 in FFF im ooo FFF uoc orsono) s (vH-m) in ooo g- 1n FFF mn K, 101 FFF sto1o1) a 3 .o 2 024 ooo FFF ooo cromo) r {Ii w"+)+z 1=1,s,. 19 Repeats 023 and 024 until all 025 002 013 FFE 13(1011) A of m, y1, ma appear inabove Sum.

.1 oss K. s FFF swim) o {EVmFFF rea-ge. .1s

. 5 .2 -gw-lvzol+tr1+v|+. 021 ooo FFF uoc orsono) s Hgm i=2,4,e...1s Repeats 026 and 027 until all 02s om 011 FFE Brion) A om, 1,. .m appear 111 prece lngsum.

The operation of the above instructions should be clear from the accompanying remarks and the explanation of the tally instruction given in the preceding problems. The address of the instruction in 023 is relative to the base counter. Since y1, y3, y, y19 are located in alternate memory cells the eiective address in this instruction must be increased by 002 each time the instruction is performed. This is accomplished by making 1r-:002 in the tally instruction. A similar situation exists in connection with the instruction in 026 and the tally instruction 02S.

After e. 3 Jiu has been added by the iinal performance of the instruction in 024 the base counter has a count of 012. In the subsequent execution of the tally instruction in 025, ae=0l4 which is greater than {35(013). The base counter is therefore reset to 0 (117:1) and the control counter is increased to 026. Similarly, after s. 3 Jia has been added by the final execution of the instruction in 027 the base counter has a count of 010. In the subsequent execution of the tally instruction in G28, a=0l2 which is greater than tctll). Therefore, the base counter is reset to 0 (br-l) and the control counter is advanced to 029 where the computer seeks its next instruction.

From the above examples it is seen that the tally instruction affords a simplified and rapid way of (l) causing the computer to repeat a set of instructions a specified number of times, and (2) changing the effective addresses in these instructions without modifying the instructions themselves.

That part of the computer control component involved in the performance of the tally instruction is shown in block form in Fig. 2. In this diagram only the gating means, the delay means, adders, etc. are illustrated. Further it is assumed that the only delays in the system are those occurring in the designated delay blocks. The illustrated circuit therefore diers from a practical circuit in that in the latter ease it would be necessary to provide produced by the various elements of the circuit such as amplifiers, gates, adders, etc. would have to be taken into account in the design of the delay elements. Since these are merely matters of design they are ignored in Fig. 2 for the sake of simplicity.

The gating means are illustrated in Fig. 2 as semicircular blocks with the output line extending from the curved side and the input lines entering through the straight side. Two types of gates, designated in the computer art as and" gates and or gates, are used. The construction and operation of such gates are well understood and are described in the literature such, for example, as the Computer Issue of the Proceedings of the Institute of Radio Engineers, vol. 41, No. l0, October 1953, pages 1300-l313 and 1381-1387. These gates may be realized in different ways, the construction of the gate being immaterial in Fig. 2 provided the desired function is performed. Briefly, an and gate is one in which an input must appear simultaneously on each of the input lines in order for an output to be produced, and an or gate is one in which an input on one or more of the input lines will produce an output. Gato 45 is an example of an and gate and gate 12 is an example of an "or" gate. The two are distinguished by having the input lines stop at the straight side in the case of an and gate and extend through to the curved side in the case of an or gate. An and gate may also be of the inhibited type, an example of which is gate 66. In this type the inhibit input line is designated by a small circle at the point where the line touches the straight side. In the case of the inhibited and gate, an output is produced only in the presence of signals on all input lines except the inhibiting input line. A signal on the inhibiting line prevents an output under any condition.

The circuit of Fig. 2 makes use of dynamic ip-tlop circuits, abbreviated FF, in several places. This type of circuit, also described on pages 1309-1310 of the above cited issue of the Proceedings of the I. R. E., has two stable conditions in one of which oit it has no output and in the other of which on it has an output in the form of a one megacycle pulse train. The 11" FF of Fig. 2 is of this type. The circuit contains a l microsecond delay loop which includes or gate 70, delay 71, and and gate 30. Assuming the FF to be ol" it may be turned on" by the application of a pulse from gate 3? to the input of gate 70. This pulse appears in the output f gate 70 and also travels around the delay loop to the input of gate '70, assuming an input to the T18 line of gate 30, so that 1 microsecond later a second pulse appears in the output of this gate. Similarly, this second pulse appears 1 microsecond later in the output of gate 70 as a third pulse, and so on. Therefore, as long as an input is maintained on the 'i218 line of gate 3l) the FF is on and has a one megacycle pulse output. Removal of the input to gate 30 on the T48 line breaks the feedback loop and returns the FF to its olf condition.

The adder 19 in Fig. 2 may be of any type capable of adding binary numbers represented by successively occurring electrical pulses. An example may be found in Fig. 13-6, page 274, of High-Speed Computing Devices, Engineering Research Associates, McGraw-Hill, 1950.

The operation of the circuit of Fig. 2 is governed by a number of control voltages which are described as follows:

F1, F1, F3, F1: These voltages represent the four phases or major cycles through which the computer passes in executing an instruction. Each is a train of one megacycle pulses and has a duration of one or more minor cycles of 48 microseconds as defined in Fig. 1.

By: A train of 48 one megacycle pulses occurring during the first minor cycle of each phase.

T1T.1: Each represents one pulse per minor cycle occurring at the time indicated.

'P1-T48: Each represents all 48 pulses of each minor cycle except the pulse occurring at the time indicated.

B: A train of one megacycle pulses on during performance of the tally instruction.

The B control voltage is generated by staticizer and decoder l. The function of this device is to analyze the operation code of an instruction and energize appropriate control lines which condition the computer to carry out the operation called for by the code. The B control line is energized in response to the A operation code of the tally instruction and conditions the computer to execute the tally instruction. Such a decoder is an essential part of all stored program digital computers and is therefore a well known item in the computer art. See, for example, Fig. 5 on page 1363 and the paragraph starting at the bottom of this page in the Proceedings of the Institute of Radio Engineers, vol. 4l, No. l0, October 1953. The remaining of the above described voltages are generated by apparatus generally indicated by blocks 2, 3 and 4. Since the design of these elements forms no part of the invention they are not shown in detail.

The operation of Fig. 2 in response to a tally instruction is as follows:

As already mentioned the execution of an instruction takes place in four phases, F 1, F2, F3 and F1 of computer operation. The diagram in Fig. 3 illustrates the timing of the various operations taking place in the execution of the tally instruction and will be helpful in understanding the following description. In F1 the tally instruction enters the instruction storage loop 5, abbreviated ISL, from the memory. The ISL comprises a 48 microsecond delay line 6, inhibited and gate 7 and or gate 8. During the trst minor cycle Ey of F1 the tally instruction arrives from the memory on line bal and enters the ISL through gates 9 and 8, the digit P1 (Fig. 1) entering first. At the same time gate 7 is inhibited, l?1r being on, so that anything already in the loop is erased. At the end of Ey, which in this case is also the end of F1, the tally instruction is in the ISL The operation code digits P11-P5 (Fig. l), which for the tally instruction are A0010), enter the ISL and are applied to the staticizer and decoder 1 at times T11-T5 of the iirst minor cycle (By) of F1. Therefore, during F1 the B output line of the staticizer and decoder is energized.

l0 During F1 (phase 2) =lb(Cs) is generated and sent to the arithmetic unit. This is accomplished as follows:

One input of gate 10 in address selector circuit 11 is connected to the 10 microsecond tap of delay line 6 in the ISL. This gate passes every pulse appearing at this tap during F1 of B (tally) operation. The output of gate 10 passes through gate 12 to one of the inputs to gate 13 in the address gating circuit 14. The address gating FF l5 is turned on in F1 by gate 16 at T11 and off by inhibiting gate 17 at T11. The output of this FF therefore is a series of 12 one megacycle pulses occurring at times T32-T43 of F2; which pulses are applied to another input of gate 13. Since the third input of gate 13 has the F2 control pulses applied thereto, this gate passes all of the pulses occurring at tap 10 of delay line 6 at times T11-T43. As may be determined from Fig. l, the digits appear at the 10 microsecond tap Vat times T11-T13, and is thus gated through gates 13 and 18 to adder 19.

The b digit of the relative address control group appears at the 22 microsecond tap of delay line 6 at T31, of F1. If a pulse appears at this time (b=1) it is v passed through gate 20 of relative address FF 21 and turns this FF on. FF 21 is turned off by gate 22 at T18. Therefore, if b=1, the output of FF 21 is a train of one megacycle pulses occurring at T30-T17. After a one microsecond delay by element 23 these pulses are applied to gate 24 of FF #25 at T11-'l".11. FF #25 is turned on by gate 24 at T31 and off by gate 26 at T41. Therefore if b=l, the output of FF #25 is a train of 12 pulses at times TS1-T43 of F1. If b=0 this FF has no output.

During F1, in the execution of the tally instruction (B on) the d FF is turned on by gate 27 at T1 and off by gate 30 at T18. The resulting output of this FF is a series of pulses from T7 to T4, which are applied to input circuits of gates 31 and 32. Gates 31 and 32 serve to gate the contents of the control counter Cc and the base counter Cb, respectively, to the adder 19. Dur ing F2 (and F3), however, Cc can not be so gated because of the inhibiting action of the output of the d" FF on gate 31. The address, therefore, if relative, must be relative to Ch. If b=l, the l2-pulse output of FF #25 permits the l2-dgit contents of C1, to be gated to adder 19 at Taz-T43. If b=0, there is no output from FF #25, as already explained, and the contents of Cb do not reach the adder. The output of the adder is a l2-digit word at Tg2-T43 representing the desired sum e=+b(cb) which passes through gate 33 to the arithmetic unit 34, this gate being open during F1 (and F3) of the B or tally operation.

During F3 (phase 3) of the tally operation the sum is obtained and sent to the arithmetic unit; also C1, is reset to ae. This is accomplished as follows:

In F3 the tally instruction is gated from the 46 microsecond tap of delay line 6 through gate 35 and gate 12 of the address selector circuit to gate 13 of the address gating circuit 14. Again, in F3, the address gating FF 15 is turned on by gate 16 at T11 and off by gate 17 at T44, and its output train of 12 pulses occurring at times T3g-T13 is applied to gate 13. Since the l2digit a word appears at the 46 microsecond tap and at gate 13 at Tag-T43, this word is gated through gates 13 and 18 to adder 19.

Gate 36 of the relative address FF 21 senses the relative address control digit a at the 22 microsecond tap of delay line 6 at T31. If a pulse is present at T31, in-

?! dicating that a=1, the relative address FF is turned on by gate 36 at T31 and 0E by gate 22 at T43. The output pulse train of this FF, after a one microsecond delay by element 23, is applied to gate 24 of FF #25 at T32-T43. As a result, FF #'25 is turned on by gate 24 at T33 and off by gate 26 at T44. The resulting output pulse train, occurring at T33-T43, is applied to gates 31 and 32 as before.

The operation of d FF 28 is the same as in F2. Its output pulse train, occurring vat TT-T, operates as in F3 to inhibit gate 31 but to act in the presence of an output from FF #25 (a=1) to apply the output of Cb through gate 32 to adder 19 during the interval T33Jl`43. The output of the adder therefore is a 12-digit word at T33-T43 representing the desired sum ae:a+a(cb) which passes through gate 33 to the arithmetic unit 34. If a=0, there is no output from FF #25 and therefore gate 32 does not open since one of its inputs is deenergized. In this case a only appears in the output of adder 19.

The base counter Cb is reset to ab in the following manner:

The count in Cb is always a l2-digit binary number. The counter comprises a 12 microsecond delay line 37 connected through gates 38 and 39 in a closed loop. A Word once inserted in the counter circulates around this loop until erased. Words are inserted through gate 4l) which is controlled by FF #41. 'This PF is turned on by gate 42 at T35 and off by gate 43 at T43. Therefore the l2 digits of any word that happens to be in the counter always appear at the tap or input of line 37 at Tab-T46. However, since the 12 microsecond delay of the loop is only 1A minor cycle the word circulates four times during each minor cycle and therefore its digits appear at the 0 tap also at the times T43-T10, T11-3F32, and T33-T34. From this it is apparent that the digits appear at the 9 microsecond tap of line 37 at the times 'FM-T7, rrif-Tag, T20-T31 and Tg2-T43, the latter agreeing with the output of FF #125 which, as already explained, serves to gate the contents of Cb through gate 32 to adder 19.

During the rst minor cycle Ey of F3, FF #41 is turned on at T33 and off at T4, in the above described manner. The resulting output, occurring at T33-T43, inhibits gate 38 during this period, thus erasing the previous count, and opens gate 40 to any pulses occurring during this period. ae occurs in the output of adder 19 at T33-T43 and, after a 3 microsecond delay by element 44, is applied to gate 40 at T35-T43 through which it enters Cb, thus resetting the base counter to ab.

The arithmetic unit 34 subtracts e applied to it in F2 from ae applied to it in F3. lf ate e the difference is negative and the asap line is energized with a continuous train of one megacycle pulses. If abe the ascp line is not energized.

The arithmetic unit 34 is of course the arithmetic unit for the entire computer and in it are performed the arithmetic processes of addition, subtraction, multiplication and division for all operations of the computer. An arithmetic unit is found in and is an essential component of all stored program automatic digital cornputers. In computers in which provision is made for a conditional transfer operation, and such provision may be considered universal in modern computers, the arithmetic unit determines if the condition calling for the transfer exists. Conditional transfer, which also goes under such names as algebraic comparison, absolute comparison, jump if minus, etc., involves a deviation from the regular stored sequence of instructions in the computer. The condition calling for this deviation is usually that a lirst specied number be less than a second specified number. The arithmetic unit determines if this condition exists by subtracting the second number from the first and sensing the sign of the difference. If minus, a control circuit is energized calling for a transfer or jump to a specied instruction address. Arithmetic units with means for sensing and signaling the conditional transfer situation are therefore well known in the art. An example is given in Fig. 4 on page 1303 of the Proceedings of the Institute of Radio Engineers, vol. 41, No. 10, October 1953. Here the sign determining unit has a line designated to control unit which is energized when the number in memory address a is less than the number in memory address and causes a conditional transfer operation to be performed. See the second paragraph of the second column on page 1303 and the descriptions of the comparison operations in Table I on page 1302. The tally instruction involves a conditional transfer in that if ot, {:`ta the computer refers to the instruction in the address ye rather than the next instruction in the sequence of instructions. The arithmetic unit of Fig. 4 in the above cited reference can sense this condition and therefore can be used for block 34 in Fig. 2 in this application, the line marked to control unit corresponding to the ascp line in Fig. 2.

The computer now progresses to F4 (phase 4) in its execution of the tally instruction. In this phase one of two possible courses of action are taken depending upon whether ascp is energized (ab e) or deenergized (aee. lf ascp is energized, Cc is reset to we. If deenergized, one is added to Cc and Cb is reset to 0 if d=1 or left at ab, to which it was set in F3 if d=0. The operation is as follows:

During F3 the tally instruction is gated from the 22 microsecond tap of delay line 6 through gates 45 and 12 of the address selector circuit to gate 46 of the address gating circuit. Also, PF #53 is turned on by gate 47 at T4 of F4 and remains on until the end of F4 when it is turned oil by gate 48. The first pulse of the FF #53 output, after a delay of 1 microsecond, is applied to gate 49 of FF #50 and, after delay of an additional microsecond, is applied as an inhibiting pulse to the same gate. Therefore, only one pulse passes gate 49 which turns on FF #50 at T5. FF #'50 is turned off at T43 by gate 51. This FF, therefore, is turned on only once during F4, its output E4 occurring at f5-T43 of the first minor cycle of F4. This control voltage insures that the control counter will be reset only in F4 and then only once.

If the ascp line is energized (ae e), the address gating FF 15 is turned on in F4 by gate 52 at T33 and off by gate 17 at T44. The 12-pulse output, occurring at T32-T43, is applied to gate 46 and serves to gate y, occurring also at '13g-T43, through gates 46 and 18 to adder 19.

The c digit of the relative address Control group is sensed at the 22 microsecond tap of delay line 6 at T33 by gate 54 of the relative address FF. If a pulse is present, indicating that c=l, FF 21 is turned on by gate 54 at T23 and off by gate 22 at T43. The resulting output, extending from T33 to T43, allows FF #25 to be turned on by gate 24 at T33 and off by gate 26 at T producing an output occurring at T33-T43.

The control counter Cb is similar to thc hase counter Cb, already described, and has the same timing. The 12-digit binary word in Cc circulates around a closed l2 microseeond loop consisting of 12 microsecond delay line 55 and gates 56 and 57. The count in Cb is changed by inserting the new count through gate 58 at T33-T43 while, at the same time, erasing the preceding count by inhibiting gate 56. As in Cb, gates 58 and 56 are controlled by the output of FF #59 which is turned on by gate 69 at T33` and off by gate 60 at T43, producing an output occurring at T33-T43 As in the case of Cb, the count appears at the 9 microsecond tap of line 55 at Tas-'T43- The d FF 28 does not go on in F4 and, with no output from this FF, gate 31 is not inhibited and per- 13 mits the contents of Cc to pass through this gate to adder 19 provided FF #25 is on (C=l). The absence of an output from the d FF also blocks the application of the C1, contents to the adder through gate 32.

The output of adder 19in phase 4, therefore, occurring This address, which is the address in the memory from which the computer obtains its next instruction, is applied to the address comparator which performs the operations necessary to obtain the desired instruction from the memory. Also, the control counter Cc is reset to 'ye which, after a 3 microsecond delay by element 44, is applied to gate 58 at T35-T46. Since, as already explained, E1 is on at T11-T47 of the first minor cycle of F1, FF #59 is turned on by gate 69 at T35 and otf by gate 60 at T17 of this minor cycle. The output of this FF serves to open gate 58 at Tg5-T46 for the new count and to simultaneously inhibit gate 56 for the purpose of erasing the old count.

The count in Cb, which was set to a, in F3, is not disturbed since FF #41 does not go on because of the inhibiting eiect of the ascp signal on gate 63. With no output from FF #41, gate 38 of C1, is not inhibited and the contents of the counter are not erased, Gate 40 is not open during F4 so that no input to Cb can occur.

If (fyee) the ascp line is not energized. In this case address gating FF 15 is not turned on by gate 52 and, therefore is not applied through address gating circuit 14 to adder 19. However, gate 61 lets one pulse through to the adder at T32. Further, regardless of the value of 6, relative address FF 21 is turned on at the start of F1 by gate 62, ascp being otf, and its output enables FF #25 to be turned on at T12 and otf at T11 in the usual manner, thus gating the contents of Cc to adder 19 through gate 31. The output of the adder, therefore, is Cc-t-l and the computer proceeds through the address comparator to seek its next instruction from this address. The control counter is also reset to Cc-lel in the same manner as for ,fe, described above.

One further operation must be carried out: that of setting C1, to if d=l. The control digit d appears at the 22 microsecond tap of line 6 at T1111. If d=l a pulse appears at T23 which is applied to gate 63 of FF #41 during the iirst minor cycle F.y of F4. With ascp not energized, FF #41 is turned on by this gate at T18 and off by gate 43 at T17. Gate 38 therefore is inhibited during the period T28-T411, and since the contents of C1, appear at this gate at Tay-T41, C1, is cleared or reset to zero. It d" had been t) instead of l, FF `1li-'41 would have not been turned on by gate 63 and the count in C1, would have remained at ce to which it was set in F3.

The operation of Fig. 2 in executing a conventional arithmetic instruction, such as one calling for the addition of two numbers, is as follows:

As already stated, in a conventional arithmetic instruction ae and are the effective addresses of the two operands and ye is the etective address of the memory cell in which the result is to be stored. These addresses may be absolute or relative, depending upon whether a, b and c are 0 or 1, and they may each be relative to a control counter Cc or a base counter C1, depending upon whether d=0, or d=1, respectively. In executing an instruction of this type e is determined in F1, ae in F2, '11,a in F3 and Cc is advanced by one in F4. Reference to the timing diagram of Fig. 4 will aid in understanding the following description.

The instruction enters the ISL during Ey of F1 through gates 9 and 8, the digit P1 (Fig. 1) entering first. The staticizer and decoder first senses the operation code (P11-P5) and energizes the proper control line or lines to condition the computer to perform the arithmetical operation called for.

In F1, is gated from the microsecond tap of line 6 through gates 10 and 12 of the address selector circuit 11 and gate 13 of the address gating circuit 14 to adder 19, address gating FF 15 having an output from T11-T11. The b digit is sensed at the 22 microsecond tap by gate 20 at T311. If b=1 a pulse appears at T110 which initiates an output from relative address FF 21 at T10-T47 which output in turn results in an output from FF #25 at r.F3n-Illa.

The d" FF 28 senses the d digit at the output of one microsecond delay element 29 at T7. If d=1 a pulse appears at T7 and d FF 28 is turned on at T7 and off at T18. The d FF output inhibits gate 31 and prevents the contents of Cc from reaching adder 19. The contents of Cb, however, may pass through gate 32 to the adder provided there is an output from FF #25 (b=1). If d==0, there is no output from the d FF, in which case Cc is gated through gate 31 to the adder if there is an output from FF #25 (b=l), and C1, is blocked at gate 32. The output of adder 19 in F1, 13,1,

This output occurs at T12-T13 of the first minor cycle of F1 and is the memory address of the first operand. This address is applied to the address comparator which operates to eiect read-out of the operand from the corresponding memory cell.

In F2, ae is obtained at the output of adder 19 and applied to the address comparator by a similar process to that described above for e. The a portion of the instruction is gated from the 46 microsecond tap of delay line 6 through gates 64 and 12 of address selector circuit 11 and gate 13 of the address gating circuit 14 to adder 19, address gating FF 15 being on in F1 as in F1 for the period Tag-T11. The control digit a" is sensed at the 22 microsecond tap of line 6 by gate 65 at T71. The presence of a pulse, indicating that crc-:1, results in FF #25 being on for the period Tar-T43 as in F1. If a=1, either Cc or C1, is gated to adder 19 depending upon whether d=0 or dzl, the operation of the d FF being the same as in F1. The output of the adder in F2 therefore is:

d=l ae=ot+a(cb) The second operand is obtained in F2 from the memory cell corresponding to ae by the address comparator, and the arithmetical process on the two operands also performed in this phase.

In F3, ye is obtained at the ouput of adder 19 by a process similar in all respects to those described for e and me. The 'y portion of the instruction is gated from the 22 microsecond tap through gates 66 and 12 of the address selector circuit and gate 13 of the address gating circuit to adder 19. The c digit is sensed at the 22 microsecond tap of delay line 6 by gate 67 of the address gating FF at T29. The d digit is sensed by the d FF as before. As in the cases of b and a in F1 and F1, if c=1 either Cc or C1, is gated to the adder depending upon whether d--O or d=l, respectively. The output of the adder in F3 therefore is d=1 'Ye=^/|C(Cv) Through operation of the address comparator the arithmetical result is read into the memory cell corresponding t0 7e.

In F4, l is added to the control counter C,J to obtain the address of the next instruction. The process is as follows:

Neither the address selector 11 nor the address gating FF 15 has an output in F1. However, FF #53 and FF #'50 operate to produce E1 at T5T17 as explained in F4 of the tally instruction. Therefore one pulse passes gate 61 of the address gating circuit at T33 as is applied through gate 18 to adder 19.

The d FF does not go on in F4. As a result gate 32 is closed and only the control counter Cc can be .gated to adder 19. The relative address FF 21, however, ls turned on at the start of F4 by gate 68, which results in FF #25 being on during the period Taz-T43. The count in Cc is therefore gated through gate 31 to adder 19 at T33-T43 where it is added to the l applied to the adder at T3, by the address gating circuit. The output of the adder therefore is Cc-l-l which is applied to the address comparator as the address of the next instruction.

The control voltage E4 also allows FF #59 to be turned on by gate 69 at T35 and olf by gate 60 at T47. Cc|1 is applied through 3 microsecond delay 44 to gate 58 at Tg-T46. Therefore the Tas-T output of FF #59 inserts Cc-i-l into the control counter and erases the previous count Ce. For any succeeding minor cycles in F4 the count in the control counter remains at Cc-l-l since gate 28 produces an output pulse at T32 only in the presence of E., and, therefore, only in the rst minor cycle of F4.

Although the specilc control circuits of Fig. 2 are designed for use with three-address instructions the invention is equally applicable to a computer using instructions of the four-address type. In the four-address system a control counter is not used to designate the next instruction as in the three-address system. Instead, a fourth address, designated the address, is added to the instruction for this purpose. Therefore, a tally instruction of the four-address type would contain a, and 'y addresses serving the same purposes as in the three-address tally instruction and in addition a address designating the location of the next instruction. Accordingly, in the execution of the instruction, the operation for the ae e condition would be the same as in the three-address case while for the aege condition, instead of increasing C,J by one, the computer would seek its next instruction from the location indicated by the address.

1 claim:

l. In an automatic digital computer employing instructions having at least three addresses and a base counter to which said addresses may be relative: apparatus for executing a tally instruction, said apparatus comprising means for adding the numerical value of one of said addresses to the contents of said base counter, means for comparing the resulting sum with the numerical value of a second of said addresses, means associated with said comparing means and said base counter and operative when said sum is less than the numerical value of said second address to increase the count in the base counter by the numerical value of said one address and to seek the next instruction at the place indicated by said third address, and means associated with said comparing means and operative when said sum is equal to or greater than the numerical value of said second address to refer the computer to an instruction other than the instruction at the place indicated by said third address.

2. In an automatic digital computer employing threeaddress instructions and having a control counter for designating the next instruction and a base counter, and in which each of said addresses may be relative to either of said counters: apparatus for executing a tally instruction, said apparatus comprising means for adding the numerical value of one of said addresses to the contents of said base counter, means for comparing the resulting sum with the numerical value of a second of said addresses, and means, associated with said comparing means and said control and base counters, operative when said sum is less than the numerical value of said second ad dress to increase the count in the base counter by the numerical value of said one address and to reset said I6 control counter to a value determined by the third of said addresses and operative when said sum is equal to or greater than the numerical value of said second address to increase the count of said control counter by one.

3. In an automatic digital computer employing threeaddress instructions and having a control counter for designating the next instruction and a base counter, and in which each of said addresses may be relative to either of said counters: apparatus for executing a tally instruction, said apparatus comprising means for adding the numerical value of one of said addresses to the contents of said base counter, means for comparing the resulting sum with the numerical value of a second of said addresses, and means, associated with said comparing means and said control and base counters, operative when said sum is less than the numerical value of said second address to increase the count in the base counter by the numerical value of said one address and to reset said control counter to a value determined by the third of said addresses and operative when said sum is equal to or greater than the numerical value of said second address to reset said base counter to a predetermined count and to increase the count in said control counter by one.

4. In an automatic digital computer using instructions each containing a first address, a second address and a third address, each address being a binary number, in which there are provided a control counter for designating the next instruction and a base counter, and in which each of said addresses may be relative to one of said counters, apparatus for executing a tally instruction, said apparatus comprising: means for comparing a first quantity which is one of a group of two quantities consisting of the absolute value of the tirst address of said tally instruction and the sum of said absolute value and the contents of said base counter with a second quantity which is one of a group of two quantities consisting of the absolute value of the second address of said tally instruction and the sum of said absolute value and the contents of said base counter, and means, associated with said comparing means and said control and base counters, operative when said first quantity is less than said second quantity to reset said base counter to said first quantity and said control counter to one of a group of two quantities consisting of the absolute value of the third address of said tally instruction and the sum of said absolute value and the contents of said control counter and operative when said rst quantity is not less than said second quantity to increase the count in said control counter by one.

5. In an automatic digital computer using instructions each containing a rst address, a second address and a third address, each address being a binary number, in which there are provided a control counter for designating the next instruction and a base counter and in which each of said addresses may be relative to one of said counters, apparatus for executing a tally instruction, said apparatus comprising: means for comparing a first quantity which is one of a group of two quantities consisting of the absolute value of the first address of said tally instruction and the sum of said absolute value and the contents of said base counter with a second quantity which is one of a group of two quantities consisting of the absolute value of the second address of said tally instruction and the sum of said absolute value and the contents of said base counter, and means, associated with said comparing means and said control and base counters, operative when said first quantity is less than said second quantity to reset said base counter to said first quantity and said control counter to one of a group of two quantities consisting of the absolute value of the third address of said tally instruction and the sum of said absolute value and the contents of said control counter and operative when said tirst quantity is not less than said second quantity to reset said base counter to one of a group of two quantities consisting of said 1"'1 1s first quantity and zero and to incras the count in said OTHER REFERENCES comm] munter by one' A Functional Description of the Edvac vol. 1I, Unie't fP sl ',R hR t5-9,N.1, References Cited ln the lle of tins patent llgy (gig. elnglfl esearc epm ov UNITED STATES PATENTS 5 Auerbach: The Binac Proc. IRE; January, 1952, 2,604,262 Phelps July 22, 1952 pages 12-28- 2,636,672 Hamilton Apr. 28, 1953 FQREIGN PATENTS 709,407 Gum Britain May 26, 1954 l 

